package com.bao.grpc.users.controller;

import com.bao.grpc.users.service.IUsersService;
import com.bao.grpc.users.mapper.UsersMapper;
import com.bao.grpc.users.model.Users;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
public class TestController {

    @Autowired(required=false)
    UsersMapper aaaa;

    @Autowired(required=false)
    IUsersService bbbb;

    @ResponseBody
    @RequestMapping(value = "/getList")
    public List<Users> getList(){

        System.out.println(bbbb);
        System.out.println(aaaa);
        List<Users> list = aaaa.selectList(null);
        return  list;
    }
}
